package com.kuaiyin.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;

import java.io.Serial;
import java.io.Serializable;

import com.kuaiyin.sampling.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 全局变量表
 * </p>
 *
 * @author ng
 * @since 2025-04-25
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("environment")
@Schema(name = "Environment", description = "全局变量表")
public class Environment extends BaseEntity implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "变量ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @Schema(description = "变量名（唯一，如base_url）")
    private String varName;

    @Schema(description = "环境类型")
    private String environmentType; // DEV, TEST, STAGING, PROD

    @Schema(description = "变量值")
    private String varValue;

    @Schema(description = "变量类型")
    private String varType;

    @Schema(description = "是否加密（0-明文，1-加密）")
    private Boolean isEncrypted;

    @Schema(description = "变量说明")
    private String description;

}